package com.csii.modules.system.service.impl;

import com.csii.core.api.Result;
import com.csii.core.system.vo.SyncDictVo;
import com.csii.galaxy.studio.entity.ActStartFlowInstance;
import com.csii.galaxy.studio.entity.ActStartFlowInstanceIframeUrl;
import com.csii.galaxy.studio.entity.SendMessage;
import com.csii.galaxy.studio.service.GalaxyStudioBaseService;
import com.csii.modules.system.controller.*;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;
import java.util.Map;

@Service
public class GalaxyStudioBaseServiceImpl implements GalaxyStudioBaseService {

    @Autowired
    SysDictController sysDictController;

    @Autowired
    SysLogController sysLogController;
    @Autowired
    CommonController commonController;
    @Autowired
    SysAnnouncementController sysAnnouncementController;

    @Autowired
    OauthClientDetailsController oauthClientDetailsController;

    @Override
    public String queryTableDictTextByKey(String table, String text, String code, String key) {
        return sysDictController.queryTableDictTextByKey(table,text,code,key);
    }

    @Override
    public String queryDictTextByKey(String code, String key) {
        return sysDictController.queryDictTextByKey(code,key);
    }

    @Override
    public String parseTemplateByCode(String templateCode, Map<String, String> map) {
        return commonController.parseTemplateByCode(templateCode,map);
    }

    @Override
    public Result sendSysAnnouncement(SendMessage sendMessage) {
        return null;
    }

    @Override
    public Result sendSysAnnouncementAct(String actBusId, String fromUser, String toUser, String title, String msgContent) {
        return sysAnnouncementController.sendSysAnnouncementAct(actBusId,fromUser,toUser,title,msgContent);
    }

    @Override
    public SyncDictVo syncDict(String redisListKey,Integer lastSyncResult) {
        return sysDictController.syncDict(redisListKey,lastSyncResult);
    }

    @Override
    public Result<List<String>> queryClientIdList() {
        return oauthClientDetailsController.queryClientIdList();
    }

    @Override
    public Result pay(String appCode, int count) {
        return null;
    }

    @Override
    public Result costAuth(String appCode) {
        return null;
    }

    @Override
    public Result startFlowInstanceByKey(ActStartFlowInstance startFlowInstance) {
        return null;
    }

    @Override
    public Result startFlowInstanceIframeUrlByKey(ActStartFlowInstanceIframeUrl startFlowInstanceIframeUrl) {
        return null;
    }
}
